#include "junix.h"

unsigned long myinet_aton(const char *s)
{
    int a, b, c, d;

    if (!s)
	return 0;
    if (sscanf(s, "%d.%d.%d.%d", &a, &b, &c, &d) != 4)
	return 0;
    return (a << 24) + (b << 16) + (c << 8) + d;
}

int main(int argc, char **argv)
{
	printf( "%ld\n",myinet_aton("127.0.0.1") );
	return 0;
}

